From 7b18165a5e75f68694b3be6897b25d03edee15c5 Mon Sep 17 00:00:00 2001 From: Keir Fraser Date: Wed, 15 Jul 2009 09:14:19 +0100 Subject: [PATCH] x86: Fix an oversight of c/s 19927 - per-CPU data accesses must not be iterated over using NR_CPUS bound loops. Signed-off-by: Jan Beulich --- xen/arch/x86/smpboot.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/xen/arch/x86/smpboot.c b/xen/arch/x86/smpboot.c index 5a18b9be1a..203c3682f6 100644 --- a/xen/arch/x86/smpboot.c +++ b/xen/arch/x86/smpboot.c @@ -1163,7 +1163,7 @@ static void __init smp_boot_cpus(unsigned int max_cpus) * construct cpu_sibling_map, so that we can tell sibling CPUs * efficiently. */ - for (cpu = 0; cpu < NR_CPUS; cpu++) { + for_each_cpu(cpu) { cpus_clear(per_cpu(cpu_sibling_map, cpu)); cpus_clear(per_cpu(cpu_core_map, cpu)); } -- 2.30.2